import {
  createRouter,
  createWebHistory,
  createWebHashHistory
} from "vue-router"

const routes = [
  // 整体概况
  {
    path: "/overallOverview",
    name: "overallOverview",
    component: () => import("@/views/overallOverview/index.vue")
  },
  // 农作物产值分析
  {
    path: "/AnalysisCropOutput",
    name: "AnalysisCropOutput",
    component: () => import("@/views/AnalysisCropOutput/index.vue")
  },
  // 气象监测
  {
    path: "/meteorologicalMonitoring",
    name: "meteorologicalMonitoring",
    component: () => import("@/views/meteorologicalMonitoring/index.vue")
  },
  // 虫情监测
  {
    path: "/InsectMonitoring",
    name: "InsectMonitoring",
    component: () => import("@/views/InsectMonitoring/index.vue")
  },
  // 视频监控
  {
    path: "/videoMonitoring",
    name: "videoMonitoring",
    component: () => import("@/views/videoMonitoring/index.vue")
  },
  // 人员管理
  {
    path: "/staffManagement",
    name: "staffManagement",
    component: () => import("@/views/staffManagement/index.vue")
  },
  // 物料管理
  {
    path: "/materialManagement",
    name: "materialManagement",
    component: () => import("@/views/materialManagement/index.vue")
  },
  // 设备统计
  {
    path: "/equipmentStatistics",
    name: "equipmentStatistics",
    component: () => import("@/views/equipmentStatistics/index.vue")
  },
  // 罐区管理
  {
    path: "/tankAreaManagement",
    name: "tankAreaManagement",
    component: () => import("@/views/tankAreaManagement/index.vue")
  }
]
const router = createRouter({
  // hash 模式: createWebHashHistory
  // history 模式 : createWebHistory
  // history: createWebHistory(),
  history: createWebHashHistory(),
  routes
})

export default router
